package com.marvels.financial.collection.service;

import java.util.List;
import java.util.Map;

import org.apache.poi.hssf.usermodel.HSSFWorkbook;

import com.github.pagehelper.Page;
import com.github.pagehelper.PageInfo;
import com.marvels.common.dto.MarvelsResultDTO;
import com.marvels.common.exception.MarvelsBusinessException;
import com.marvels.financial.collection.dto.CaseInfoDTO;
import com.marvels.financial.collection.dto.CollectAccountDTO;
import com.marvels.financial.collection.dto.CollectCommonModularInfoDTO;
import com.marvels.financial.collection.dto.CollectListConditionDTO;
import com.marvels.financial.collection.dto.CollectListInfoDTO;
import com.marvels.financial.collection.dto.CollectTransferDTO;
import com.marvels.financial.collection.dto.CommonConditionDTO;
import com.marvels.financial.collection.dto.McfeCollecteActionRecordDTO;
import com.marvels.financial.collection.dto.McfeOverdueCollectionActionCodeDTO;
import com.marvels.financial.collection.dto.McfeOverdueCollectionActionStatusDTO;
import com.marvels.financial.collection.dto.McfeOverdueCollectionCollectionVisitDTO;
import com.marvels.financial.collection.dto.McfeOverdueCollectionVerificationDTO;
import com.marvels.financial.collection.dto.OnlineDeductionDto;
import com.marvels.financial.collection.dto.OverDueTransInfoDTO;
import com.marvels.financial.loan.dto.McfeCustomerLoanContractDTO;
import com.marvels.financial.loan.dto.McfeCustomerRepaymentPlanDTO;

public interface CollectManageApi {

	/**
	 * 催收初始化条件
	 * @return
	 */
	public MarvelsResultDTO collectCondition()  throws MarvelsBusinessException;
	
	
	
	/**
	 * 催收列表信息
	 * @param condition
	 * @return
	 * @throws MarvelsBusinessException
	 */
	public Map<String, Object> collectList(CollectListConditionDTO condition)throws MarvelsBusinessException;
	
	/**
	 * 更新催收处理时间
	 * @param condition
	 * @return
	 * @throws MarvelsBusinessException
	 */
	public void updateCollecteDate(CollectListConditionDTO condition)throws MarvelsBusinessException;
	
	/**
	 * 催收转派列表
	 * @param condition
	 * @return
	 * @throws MarvelsBusinessException
	 */
	public Map<String, Object> collectTransferList(CollectListConditionDTO condition)throws MarvelsBusinessException;
	
	/**
	 * 下载excel
	 * @param condition
	 * @return
	 */
	public HSSFWorkbook downLoadExcel(CollectListConditionDTO condition) throws MarvelsBusinessException;
	
	
	
	/**
	 * 线下委外excel下载
	 * @param condition
	 * @return
	 */
	public HSSFWorkbook downOutsideExcel(CollectListConditionDTO condition) throws MarvelsBusinessException;
	
	
	/**
	 * 催收公共模块信息
	 * @param condition
	 */
	public CollectCommonModularInfoDTO commonModularInfo(CollectListConditionDTO condition)  throws MarvelsBusinessException;
	
	
	/**
	 * 行动结果
	 * @param dto
	 * @return
	 */
	public List<McfeOverdueCollectionActionStatusDTO> actionReultList(McfeOverdueCollectionActionStatusDTO dto) ;
	
	
	/**
	 * 行动code
	 * @param dto
	 * @return
	 */
	public List<McfeOverdueCollectionActionCodeDTO> actionCodeList(McfeOverdueCollectionActionCodeDTO dto);
	
	/**
	 * 新增行动信息
	 * @param dto
	 */
	public void addActionInfo(McfeCollecteActionRecordDTO dto) throws MarvelsBusinessException;
	
	
	
	/**
	 * 新增电催信息
	 * @param dto
	 */
	public void addElectricCollectInfo(McfeOverdueCollectionVerificationDTO dto) throws MarvelsBusinessException;
	
	
	/**
	 * 修改电催信息
	 * @param dto
	 */
	public void modifyElectricCollectInfo(McfeOverdueCollectionVerificationDTO dto) throws MarvelsBusinessException;
	
	
	
	/**
	 * 新增催收外访信息
	 * @param dto
	 */
	public void addCollectVisitInfo(McfeOverdueCollectionCollectionVisitDTO dto) throws MarvelsBusinessException;
	
	
	/**
	 * 上传催收外访信息
	 * @param dto
	 * @throws MarvelsBusinessException
	 */
	public MarvelsResultDTO uploadCollectVisitInfo(McfeOverdueCollectionCollectionVisitDTO dto) throws MarvelsBusinessException; 
	
	
	/**
	 * 下载催收外访文件
	 * @param dto
	 * @return
	 */
	public byte[] downLoadVisitFile(McfeOverdueCollectionCollectionVisitDTO dto) throws MarvelsBusinessException;
	
	/**
	 * 查询基本信息
	 * @param loanId
	 * @return
	 * @throws MarvelsBusinessException
	 */
	public Map<String,Object> selectBasicInfo(CollectListConditionDTO coditionDto) throws MarvelsBusinessException;
	
	
	/**
	 * 逾期短信提醒
	 * @param loanIds
	 * @throws MarvelsBusinessException
	 */
	public void overdueSmsReminder(String loanIds) throws MarvelsBusinessException;
	
	/**
	 * 查询融资账户信息
	 * @param loanId
	 * @return
	 * @throws MarvelsBusinessException
	 */
	public CollectAccountDTO selectAccountInfo(CollectListConditionDTO coditionDto) throws MarvelsBusinessException;
	
	/**
	 * 分页查询金融交易信息
	 * @param coditionDto
	 * @return
	 * @throws MarvelsBusinessException
	 */
	public PageInfo<OverDueTransInfoDTO> selectTransList(CollectListConditionDTO coditionDto) throws MarvelsBusinessException;
	
	/**
	 * 获取金融交易明细
	 * @param id
	 * @return
	 * @throws MarvelsBusinessException
	 */
	public OverDueTransInfoDTO selectTransInfoDetail(String id) throws MarvelsBusinessException;

	/**
	 * 行动信息查询
	 * @param dto
	 * @return
	 * @throws MarvelsBusinessException
	 */
	public Page<McfeCollecteActionRecordDTO> actionInfoList(McfeCollecteActionRecordDTO dto) throws MarvelsBusinessException;
	
	/**
	 * 案件信息查询
	 * @param dto
	 * @return
	 * @throws MarvelsBusinessException
	 */
	public CaseInfoDTO caseInfo(CaseInfoDTO dto) throws MarvelsBusinessException;
	
	
	/**
	 * 融资合同信息
	 * @param dto
	 * @return
	 * @throws MarvelsBusinessException
	 */
	public Page<McfeCustomerLoanContractDTO> financingContract(CommonConditionDTO dto) throws MarvelsBusinessException;
	
	
	/**
	 * 还款计划分页
	 * @param dto
	 * @return
	 */
	public Page<McfeCustomerRepaymentPlanDTO>  planList(CommonConditionDTO dto) throws MarvelsBusinessException;
	
	/**
	 * 催收转派
	 * @param collectTransferDTO
	 * @throws MarvelsBusinessException
	 */
	public void saveTransferInfo(CollectTransferDTO collectTransferDTO) throws MarvelsBusinessException;
	
	/**
	 * 线上代扣列表
	 * @param loanIds
	 * @return
	 * @throws MarvelsBusinessException
	 */
	public List<OnlineDeductionDto> onlineDeductionList(String loanIds, String channel) throws MarvelsBusinessException;
}
